<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title>resource owner password credentials</title>
</head>

<body>
<div>
    <h1>密码模式（resource owner password credentials）</h1>
</div>

<div>
    <h2>流程图</h2>
    <img src="../img/wf_password.png">
</div>

<div>
    <h2>举个例子</h2>

    <table>
        <tr>
            <td>Username</td>
            <td><input id="username" type="text" value="admin"/></td>
        </tr>
        <tr>
            <td>Password</td>
            <td><input id="password" type="password" value="admin"/></td>
        </tr>
        <tr>
            <td colspan="2">
                <button type="button" onclick="getToken();">获取令牌</button>
            </td>
        </tr>
    </table>
</div>

<div>
    <textarea id="token" style="resize: none;min-width: 600px; min-height: 100px;"></textarea>
</div>
</body>

<script src="//code.jquery.com/jquery-1.11.2.min.js"></script>
<script type="text/javascript" charset="UTF-8" src="../js/password.js"></script>
</html>
